package com.shixun.mapper;

import com.shixun.pojo.TbBus;
import com.shixun.pojo.TbBusProblem;
import com.shixun.pojo.TbRepairRecord;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

@Mapper
public interface BusManageMapper {
    List<TbBus> selectBusInfo(@Param("busId") int busId,@Param("busName") String busName,@Param("busStatus") int busStatus,@Param("city") String city,@Param("limit") int limit,@Param("offset") int offset);

    int insertBusInfo(@Param("busName") String busName, @Param("busStatus") int busStatus, @Param("repairDriverId") int repairDriverId, @Param("city") String city);

    int modifyBusInfo(@Param("newBusName") String newBusName,@Param("newBusStatus") int newBusStatus,@Param("newRepairDriver") int newRepairDriver,@Param("newCity") String newCity);

    List<TbBusProblem> selectBrokenBus(@Param("busId") int busId);

    int setStatus1(@Param("busId") int busId);

    int setStatus3(@Param("busId") int busId);

    int setStatus4(@Param("busId") int busId);

    List<TbRepairRecord> selectRepairBus(@Param("busId") int busId);
}
